fix(gix-index): handle loongarch64-musl stat struct field names#2428
Merged
Byron merged 1 commit intoGitoxideLabs:mainfrom Feb 10, 2026
Merged
fix(gix-index): handle loongarch64-musl stat struct field names#2428Byron merged 1 commit intoGitoxideLabs:mainfrom
Byron merged 1 commit intoGitoxideLabs:mainfrom
Conversation
On `loongarch64-unknown-linux-musl` with musl 1.2.3+, the libc `stat` struct uses POSIX timespec fields (`st_mtim`, `st_ctim`) instead of separate seconds and nanoseconds fields (`st_mtime`, `st_mtime_nsec`). This was exposed by libc 0.2.180 which added proper time64 support for this target, causing compilation failures in rust-lang/rust CI. Fixes the same pattern already used for AIX and Hurd targets.
Byron
approved these changes
Feb 10, 2026
Member
Byron
left a comment
There was a problem hiding this comment.
Thanks a lot, much appreciated!
Contributor
Author
|
@Byron do you plan to cut a new release? So that I don't need to do this rust-lang/cargo#16615 Up to you. No worries :) |
Member
|
I released it for you @weihanglo, and for Cargo :). Hoping it works for you. |
weihanglo
added a commit
to weihanglo/cargo
that referenced
this pull request
Feb 10, 2026
For addressing loongarch 64bit time API issue. See GitoxideLabs/gitoxide#2428
github-merge-queue bot
pushed a commit
to rust-lang/cargo
that referenced
this pull request
Feb 10, 2026
For addressing loongarch 64bit time API issue. See GitoxideLabs/gitoxide#2428
weihanglo
added a commit
to weihanglo/cargo
that referenced
this pull request
Feb 11, 2026
Right after git-index changed accordingly via GitoxideLabs/gitoxide#2428 for the loongarch timestamp API issue, libc reverted it back rust-lang/libc#4958 and released 0.2.181 We pin to libc@0.2.180 for now. And when gitoxide reverts, we can safely upgrade them # Do not modify or remove the line above. # Everything below it will be ignored. # # On branch libc # Changes to be committed: # modified: Cargo.lock # diff --git a/Cargo.lock b/Cargo.lock index 668d2a2..204d94e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2769,9 +2769,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67" [[package]] name = "libc" -version = "0.2.181" +version = "0.2.180" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "459427e2af2b9c839b132acb702a1c654d95e10f8c326bfc2ad11310e458b1c5" +checksum = "bcc35a38544a891a5f7c865aca548a982ccb3b8650a5b06d0fd33a10283c56fc" [[package]] name = "libgit2-sys"
weihanglo
added a commit
to weihanglo/cargo
that referenced
this pull request
Feb 11, 2026
Right after git-index changed accordingly via GitoxideLabs/gitoxide#2428 for the loongarch timestamp API issue, libc reverted it back rust-lang/libc#4958 and released 0.2.181 We pin to libc@0.2.180 for now. And when gitoxide reverts, we can safely upgrade them
Contributor
Author
|
It is a bit annoying that rust-lang/libc#4958 libc reverted the change and released a 0.2.181 😓. We probably also want to revert. See also rust-lang/cargo#16624 No need to rush into a new release. And sorry about this 😞. |
Member
|
No worries, this happens and at least you will have a release if you still need one later. |
github-merge-queue bot
pushed a commit
to rust-lang/cargo
that referenced
this pull request
Feb 11, 2026
Right after git-index changed accordingly via GitoxideLabs/gitoxide#2428 for the loongarch timestamp API issue, libc reverted it back rust-lang/libc#4958 and released 0.2.181 We pin to libc@0.2.180 for now. And when gitoxide reverts, we can safely upgrade them Previous relevnat PRs: * #16615 * #16613
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This follows the same pattern already used for AIX and Hurd targets.
On this target with musl 1.2.3+,
musl switched to POSIX timespec structs for time64 support.
Loongarch in 0.2.180 was changed accordingly.
See libc 0.2.180, which added proper time64 support for
loongarch64-unknown-linux-muslwith musl 1.2.3+Found through: